import axios from 'axios'
import { Indicator } from 'mint-ui'
const $http = axios.create({
  baseURL: 'http://jsonplaceholder.typicode.com/'
})

$http.interceptors.request.use(config => {
  Indicator.open('加载中...')
  return config
})

$http.interceptors.response.use(resp => {
  Indicator.close()
  return resp
})

export default $http

// https://www.only.cn/api/goods/dmpRecommendGoods?projectName=firstPageHot&brand=one&userId=&brandCode=ONLY
